Maven best practice for generating artifacts for multiple environments [prod, test, dev] with CI/Hud

Posted by jaguard on Stack Overflow See other posts from Stack Overflow or by jaguard
Published on 2010-03-11T10:23:55Z Indexed on 2010/03/12 4:57 UTC
Read the original article Hit count: 206

I have a project that need to be deployed into multiple environments (prod, test, dev). The main differences mainly consist in configuration properties/files.

My idea was to use profiles and overlays to copy/configure the specialized output. But I'm stuck into if I have to generate multiple artifacts with specialized classifiers (ex: "my-app-1.0-prod.zip/jar", "my-app-1.0-dev.zip/jar") or should I create multiple projects, one project for every environment ?!
Should I use maven-assembly-plugin to generate multiple artifacts for every environment ? Anyway, I'll need to generate all them at once so it seams that the profiles does not fit ... still puzzled :(

Any hints/examples/links will be more than welcomed.

As a side issue, I'm also wondering how to achieve this in a CI Hudson/Bamboo to generate and deploy these generated artifacts for all the environments, to their proper servers (ex: using SCP Hudson plugin) ?

© Stack Overflow or respective owner

Related posts about maven

Related posts about maven-2